package ie.lawlor.amvc.config;

import org.springframework.beans.factory.support.BeanDefinitionRegistry;
import org.springframework.beans.factory.support.ChildBeanDefinition;
import org.w3c.dom.Element;

class ChildTriadDefinitionParser extends TriadDefinitionParser {
	
	protected ChildBeanDefinition createAndRegisterTriad(Element element,
			BeanDefinitionRegistry registry) {
		ChildBeanDefinition triadBeanDefinition = createTriadBeanDefinition(element);
		String beanName = element.getAttribute(ID);
		registry.registerBeanDefinition(beanName, triadBeanDefinition);
		return triadBeanDefinition;
	}
}